﻿/**
 ** @作者:	   王桂龙 QQ731513122
 ** @日期:	   2019.12.6
 ** @简介:     先占好位置     
 */
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Drawing;
using System.Drawing.Drawing2D;

namespace BHXJDOTNET.OLD
{
    public class BHXJPanel:Panel
    {
        public BHXJPanel()
            : base()
        {
            this.SetStyle(ControlStyles.UserPaint, true);
            this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
            this.SetStyle(ControlStyles.DoubleBuffer, true);
            //this.SetStyle(ControlStyles.ResizeRedraw, true);
            this.SetStyle(ControlStyles.ResizeRedraw, false);
            this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
            //this.SetStyle(ControlStyles.Opaque, true);

            this.SizeChanged += BHXJPanel_SizeChanged;
            //this.MouseClick += BHXJPanel_MouseClick;
        }

        private void BHXJPanel_SizeChanged(object sender, EventArgs e)
        {
            this.Invalidate(false);
        }

        private void BHXJPanel_MouseClick(object sender, MouseEventArgs e)
        {
            object a = sender;
        }

        public new bool DesignMode
        {
            get { return base.DesignMode; }
        }

        
    }
}
